<template>
  <div class="profile-info">
    <div class="pic-box">
      <img
        class="user-avatar"
        :src="require('assets/images/profile/' + getUserInfo.avatar)"
      />
    </div>
    <mt-cell title="用户名" :value="getUserInfo.name"></mt-cell>
    <mt-cell title="邮箱" :value="getUserInfo.email"></mt-cell>
    <mt-cell title="手机号" :value="getUserInfo.phone"></mt-cell>
    <mt-cell title="性别" :value="getUserInfo.gender"></mt-cell>
    <mt-cell title="金额" :value="getUserInfo.balance"></mt-cell>
  </div>
</template>

<script>
export default {
  name: "ProfileInfo",
  data() {
    return {};
  },
  created() {
    console.log(this.getUserInfo);
  },
  computed: {
    getUserInfo() {
      return this.$store.state.userInfo;
    },
  },
};
</script>

<style scoped>
.profile-info >>> .mint-cell {
  border-bottom: 1px solid var(--gray2);
}
.pic-box {
  text-align: center;
  padding: 10px 0;
}
.user-avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.5);
}
</style>